﻿using System;
using SharpSqlAnalyzer.nodes;
using SharpSqlAnalyzer.nodes.hive;

namespace SharpSqlAnalyzer.stmt.hive
{
	// Token: 0x020001C9 RID: 457
	public class THiveShowGrant : TCustomSqlStatement
	{
		// Token: 0x06000F4E RID: 3918 RVA: 0x0030B5F4 File Offset: 0x003097F4
		public THiveShowGrant(EDbVendor dbvendor) : base(dbvendor)
		{
			this.sqlstatementtype = ESqlStatementType.ssthiveShowGrants;
		}

		// Token: 0x170002DB RID: 731
		// (get) Token: 0x06000F4F RID: 3919 RVA: 0x0030B608 File Offset: 0x00309808
		// (set) Token: 0x06000F50 RID: 3920 RVA: 0x0030B610 File Offset: 0x00309810
		public virtual THivePrincipalName PrincipalName
		{
			get
			{
				return this.principalName;
			}
			set
			{
				this.principalName = value;
			}
		}

		// Token: 0x170002DC RID: 732
		// (get) Token: 0x06000F51 RID: 3921 RVA: 0x0030B619 File Offset: 0x00309819
		// (set) Token: 0x06000F52 RID: 3922 RVA: 0x0030B621 File Offset: 0x00309821
		public virtual TObjectName TableName
		{
			get
			{
				return this.tableName;
			}
			set
			{
				this.tableName = value;
			}
		}

		// Token: 0x170002DD RID: 733
		// (get) Token: 0x06000F53 RID: 3923 RVA: 0x0030B62A File Offset: 0x0030982A
		public virtual TSourceToken TableToken
		{
			get
			{
				return this.tableToken;
			}
		}

		// Token: 0x170002DE RID: 734
		// (get) Token: 0x06000F54 RID: 3924 RVA: 0x0030B632 File Offset: 0x00309832
		// (set) Token: 0x06000F55 RID: 3925 RVA: 0x0030B63A File Offset: 0x0030983A
		public virtual TPartitionExtensionClause PartitionSpec
		{
			get
			{
				return this.partitionSpec;
			}
			set
			{
				this.partitionSpec = value;
			}
		}

		// Token: 0x170002DF RID: 735
		// (get) Token: 0x06000F56 RID: 3926 RVA: 0x0030B643 File Offset: 0x00309843
		// (set) Token: 0x06000F57 RID: 3927 RVA: 0x0030B64B File Offset: 0x0030984B
		public virtual TObjectNameList Columns
		{
			get
			{
				return this.columns;
			}
			set
			{
				this.columns = value;
			}
		}

		// Token: 0x06000F58 RID: 3928 RVA: 0x0030B654 File Offset: 0x00309854
		public override int doParseStatement(TCustomSqlStatement psql)
		{
			if (this.rootNode == null)
			{
				return -1;
			}
			base.doParseStatement(psql);
			THiveShowGrantSqlNode thiveShowGrantSqlNode = (THiveShowGrantSqlNode)this.rootNode;
			this.principalName = thiveShowGrantSqlNode.PrincipalName;
			this.tableName = thiveShowGrantSqlNode.TableName;
			this.tableToken = thiveShowGrantSqlNode.TableToken;
			this.partitionSpec = thiveShowGrantSqlNode.PartitionSpec;
			this.columns = thiveShowGrantSqlNode.Columns;
			return 0;
		}

		// Token: 0x06000F59 RID: 3929 RVA: 0x0030B6BC File Offset: 0x003098BC
		public override void accept(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x06000F5A RID: 3930 RVA: 0x0030B6CC File Offset: 0x003098CC
		public override void acceptChildren(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x0400136D RID: 4973
		private THivePrincipalName principalName;

		// Token: 0x0400136E RID: 4974
		private TObjectName tableName;

		// Token: 0x0400136F RID: 4975
		private TSourceToken tableToken;

		// Token: 0x04001370 RID: 4976
		private TPartitionExtensionClause partitionSpec;

		// Token: 0x04001371 RID: 4977
		private TObjectNameList columns;
	}
}
